<template>
  <div class="search-bar">
    <el-form :inline="true" :model="formItem" class="form-filter" size="mini">
      <el-form-item>
        <el-input v-model="formItem.s_keyword" placeholder="请输入关键字..." />
      </el-form-item>
      <el-form-item>
        <el-button plain icon="el-icon-search" @click="search" />
      </el-form-item>
    </el-form>
  </div>
</template>

<script>

// 定义一个查询表单原始项
const formItem = {
  s_keyword: ''
}

export default {
  name: 'AuditLogTableFilter',
  data() {
    return {
      formItem: {
        ...formItem
      }
    }
  },
  methods: {
    // 查询按钮点击事件处理
    search: function() {
      this.$parent.filter(this.formItem)
    }
  }
}
</script>
